package com.atguigu.edu.controller;

import com.atguigu.utils.R;
import io.swagger.annotations.Api;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;

@RestController
@Api(description = "后台管理员登录-8001")
@RequestMapping("/eduservice")
@Slf4j
public class UserLoginController {
    @PostMapping("/user/login")
    public R login(){
        return R.ok().data("token","admin");
    }

    @GetMapping("/user/info")
    public R getInfo(){
//        https://wpimg.wallstcn.com/f778738c-e4f8-4870-b634-56703b4acafe.gif?imageView2/1/w/80/h/80?imageView2/1/w/80/h/80
//        https://wpimg.wallstcn.com/f778738c-e4f8-4870-b634-56703b4acafe.gif?imageView2/1/w/80/h/80
        return R.ok().data("roles","[admin]").data("name","zhangsan").data("avatar","https://wpimg.wallstcn.com/f778738c-e4f8-4870-b634-56703b4acafe.gif");

    }
}
